gen mine_id = ""
gen mine_subid_1 = ""
gen mine_subid_2 = ""
gen mine_subid_3 = ""
gen mine_subid_4 = ""
gen mine_subid_5 = ""
gen mine_merger = 0
gen mine_merger_id = ""


**
replace mine_id = "ABH" if mine_name == "Abhooz"
replace mine_id = "BHA" if mine_name == "Bonnefoi Hareng" | mine_name == "Bonnefoi-Hareng"  | mine_name == "Bonnefoi, Hareng, Homvent"
replace mine_id = "ABH-BHA" if mine_name == "Abhooz et Bonnefoi Hareng" | mine_name == "Abhooz et Bonnefoi-Hareng"
replace mine_subid_1 = "ABH" if mine_name == "Abhooz et Bonnefoi Hareng" | mine_name == "Abhooz et Bonnefoi-Hareng"
replace mine_subid_2 = "BHA" if mine_name == "Abhooz et Bonnefoi Hareng" | mine_name == "Abhooz et Bonnefoi-Hareng"
**
replace mine_id = "ADL" if mine_name == "Andenelle"
replace mine_id = "HTB" if mine_name == "Haute-Bise"
replace mine_id = "LLG" if mine_name == "Les Liégeois"
replace mine_id = "MUA" if mine_name == "Muache"
replace mine_id = "LLG-MUA" if mine_name == "Les Liégeois + Muache"
replace mine_subid_1 = "LLG" if mine_name == "Les Liégeois + Muache"
replace mine_subid_2 = "MUA" if mine_name == "Les Liégeois + Muache"
replace mine_id = "ADL-HTB-LLG" if mine_name == "Andenelle, Hautebise, Les Liégeois" | mine_name == "Andenelle, Hautebise et Les Liégeois" | mine_name == "Andenelle" & year==1904 | mine_name == "Andenelle" & year==1905  
replace mine_subid_1 = "ADL" if mine_name == "Andenelle, Hautebise, Les Liégeois" | mine_name == "Andenelle, Hautebise et Les Liégeois" | mine_name == "Andenelle" & year==1904 | mine_name == "Andenelle" & year==1905
replace mine_subid_2 = "HTB" if mine_name == "Andenelle, Hautebise, Les Liégeois" | mine_name == "Andenelle, Hautebise et Les Liégeois" | mine_name == "Andenelle" & year==1904 | mine_name == "Andenelle" & year==1905
replace mine_subid_3 = "LLG" if mine_name == "Andenelle, Hautebise, Les Liégeois" | mine_name == "Andenelle, Hautebise et Les Liégeois" | mine_name == "Andenelle" & year==1904 | mine_name == "Andenelle" & year==1905
**
replace mine_id = "ADN" if mine_name == "Andenne"
**
replace mine_id = "ADA" if mine_name == "André Dumont sous Asch"
**
replace mine_id = "ANG" if mine_name == "Angleur"
**
replace mine_id = "ANS" if mine_name == "Tassin" | mine_name == "Tassin (Levant de Liège)" | mine_name == "Tassin (Mine d'Ans)"  | mine_name == "Ans et Glain" | mine_name == "Ans" 	
**
replace mine_id = "ANT" if mine_name == "Antheit"
**
replace mine_id = "ASM" if mine_name == "Arbre Saint-Michel" | mine_name == "Arbre-Saint Michel"
replace mine_id = "BOT" if mine_name == "Bois d'Otheit"
replace mine_id = "CWA" if mine_name == "Cowa"
replace mine_id = "ASM-BOT-CWA" if mine_name == "Arbre Saint-Michel, Bois d'Otheit & Cowa" |  mine_name == "Arbre-Saint Michel, Bois d'Otheit & Cowa"
replace mine_subid_1 = "ASM" if mine_name == "Arbre Saint-Michel, Bois d'Otheit & Cowa" |  mine_name == "Arbre-Saint Michel, Bois d'Otheit & Cowa"
replace mine_subid_2 = "BOT" if mine_name == "Arbre Saint-Michel, Bois d'Otheit & Cowa" |  mine_name == "Arbre-Saint Michel, Bois d'Otheit & Cowa"
replace mine_subid_3 = "CWA" if mine_name == "Arbre Saint-Michel, Bois d'Otheit & Cowa" |  mine_name == "Arbre-Saint Michel, Bois d'Otheit & Cowa"
**
replace mine_id = "ARG" if mine_name == "Argenteau"
replace mine_id = "TRE" if mine_name == "Trembleur"
replace mine_id = "ARG-TRE" if mine_name == "Argenteau-Trembleur"
replace mine_subid_1 = "ARG" if mine_name == "Argenteau-Trembleur"
replace mine_subid_2 = "TRE" if mine_name == "Argenteau-Trembleur"
**
replace mine_id = "ARS" if mine_name == "Arsimont"
replace mine_id = "HSS" if mine_name == "Ham sur Sambre" | mine_name == "Ham-sur-Sambre"
replace mine_id = "MRN" if mine_name == "Mornimont"
replace mine_id = "HSS-ARS-MRN" if mine_name == "Ham-sur-Sambre, Arsimont et Mornimont"
replace mine_subid_1 = "HSS" if mine_name == "Ham-sur-Sambre, Arsimont et Mornimont"
replace mine_subid_2 = "ARS" if mine_name == "Ham-sur-Sambre, Arsimont et Mornimont"
replace mine_subid_3 = "MRN" if mine_name == "Ham-sur-Sambre, Arsimont et Mornimont"
replace mine_id = "FRN" if mine_name == "Franière"
replace mine_id = "DMH" if mine_name == "Deminche"
replace mine_id = "HSS-ARS-MRN-FRN-DMH" if mine_name == "Ham-sur-Sambre, Arsimont, Mornimont, Franière et Deminche"
replace mine_subid_1 = "HSS" if mine_name == "Ham-sur-Sambre, Arsimont, Mornimont, Franière et Deminche"
replace mine_subid_2 = "ARS" if mine_name == "Ham-sur-Sambre, Arsimont, Mornimont, Franière et Deminche"
replace mine_subid_3 = "MRN" if mine_name == "Ham-sur-Sambre, Arsimont, Mornimont, Franière et Deminche"
replace mine_subid_4 = "FRN" if mine_name == "Ham-sur-Sambre, Arsimont, Mornimont, Franière et Deminche"
replace mine_subid_5 = "DMH" if mine_name == "Ham-sur-Sambre, Arsimont, Mornimont, Franière et Deminche"
**
replace mine_id = "ART" if mine_name == "Artistes"
replace mine_id = "ART" if mine_name == "Artistes and Xhorre réunies: Artistes"
replace mine_id = "XHO" if mine_name == "Xhorré"
replace mine_id = "XHO" if mine_name == "Artistes and Xhorre réunies: Xhorré"
replace mine_merger = 1 if mine_name == "Artistes and Xhorre réunies: Artistes" | mine_name == "Artistes and Xhorre réunies: Xhorré"
replace mine_merger_id = "ART-XHO" if mine_name == "Artistes and Xhorre réunies: Artistes" | mine_name == "Artistes and Xhorre réunies: Xhorré"
replace mine_id = "BLL" if mine_name == "Baldaz-la-Lore"
replace mine_id = "KSL" if mine_name == "Kessales" | mine_name == "Romarin Kessales"
replace mine_id = "ART-XHO" if mine_name == "Artistes et Xhorré réunis" | mine_name == "Artistes and Xhorre réunies" | mine_name == "Artistes et Xhorré"
replace mine_subid_1 = "ART" if mine_name == "Artistes et Xhorré réunis" | mine_name == "Artistes and Xhorre réunies" | mine_name == "Artistes et Xhorré"
replace mine_subid_2 = "XHO" if mine_name == "Artistes et Xhorré réunis" | mine_name == "Artistes and Xhorre réunies" | mine_name == "Artistes et Xhorré"
replace mine_id = "ART-XHO-BLL" if mine_name == "Artistes-Xhorré et Baldaz-la-Lore"
replace mine_subid_1 = "ART" if mine_name == "Artistes-Xhorré et Baldaz-la-Lore"
replace mine_subid_2 = "XHO" if mine_name == "Artistes-Xhorré et Baldaz-la-Lore"
replace mine_subid_3 = "BLL" if mine_name == "Artistes-Xhorré et Baldaz-la-Lore"
replace mine_id = "KSL-ART-XHO-BLL" if mine_name == "Kessales-Artistes"			
replace mine_subid_1 = "KSL" if mine_name == "Kessales-Artistes"
replace mine_subid_2 = "ART" if mine_name == "Kessales-Artistes"
replace mine_subid_3 = "XHO" if mine_name == "Kessales-Artistes"
replace mine_subid_4 = "BLL" if mine_name == "Kessales-Artistes"
**
replace mine_id = "AUV" if mine_name == "Auvelais"
replace mine_id = "SRO" if mine_name == "Saint Roch"
replace mine_id = "AUV-SRO" if mine_name == "Auvelais-Saint Roch" | mine_name == "Saint Roch-Auvelais"
replace mine_subid_1 = "AUV" if mine_name == "Auvelais-Saint Roch" | mine_name == "Saint Roch-Auvelais"
replace mine_subid_2 = "SRO" if mine_name == "Auvelais-Saint Roch" | mine_name == "Saint Roch-Auvelais"
**
replace mine_id = "ABV" if mine_name == "Avroy Boverie" | mine_name == "Boverie" | mine_name == "Boverie Avroy" | mine_name == "Avroy-Boverie"
**
replace mine_id = "BAE" if mine_name == "Baelen"
**
replace mine_id = "BNX" if mine_name == "Baneux"
replace mine_id = "BFN" if mine_name == "Bonnefin"
replace mine_id = "BFN-BNX" if mine_name == "Bonnefin et Baneux" | mine_name == "Bonnefin et Baneux réunis" | mine_name == "Bonnefin Baneux" | mine_name == "Bonnefin" & year>=1864
replace mine_subid_1 = "BFN" if mine_name == "Bonnefin et Baneux" | mine_name == "Bonnefin et Baneux réunis" | mine_name == "Bonnefin Baneux" | mine_name == "Bonnefin" & year>=1864
replace mine_subid_2 = "BNX" if mine_name == "Bonnefin et Baneux" | mine_name == "Bonnefin et Baneux réunis" | mine_name == "Bonnefin Baneux" | mine_name == "Bonnefin" & year>=1864
**
replace mine_id = "BOH" if mine_name == "Bas-Oha"
**
replace mine_id = "BMA" if mine_name == "Basse Marlagne" | mine_name == "Basse-Marlogne" | mine_name == "Basse-Marlagne"
**
replace mine_id = "BRA" if mine_name == "Basse-Ransy" | mine_name == "Basse Ransy"
**
replace mine_id = "BAT" if mine_name == "Batterie"
replace mine_id = "BGC" if mine_name == "Bouck et Gaillard Cheval"
replace mine_id = "BAT-BGC" if mine_name == "Batterie, Bouck et Gaillard Cheval réunis" | mine_name == "Batterie et Bouck et Gaillard Cheval réunies" 
replace mine_subid_1 = "BAT" if mine_name == "Batterie, Bouck et Gaillard Cheval réunis" | mine_name == "Batterie et Bouck et Gaillard Cheval réunies" 
replace mine_subid_2 = "BGC" if mine_name == "Batterie, Bouck et Gaillard Cheval réunis" | mine_name == "Batterie et Bouck et Gaillard Cheval réunies" 
**
replace mine_id = "BRC" if mine_name == "Beeringen-Coursel" | mine_name == "Beering-Coursel"
**
replace mine_id = "BVS" if mine_name == "Belle Vue Saint-Laurent" | mine_name == "Belle-Vue à Saint-Laurent" | mine_name == "Belle Vue à Saint Laurent" | mine_name == "Bellevue à Saint-Laurent"  | mine_name == "Belle Vue" & mine_community == "Liège"
**
replace mine_id = "BVB" if mine_name == "Belle Vue et Bien Venue" | mine_name == "Belle Vue" & mine_community == "Herstal"
**
replace mine_id = "BEN" if mine_name == "Ben"
**
replace mine_id = "BND" if mine_name == "Bende" | mine_name == "Houillère de Bende C"
**
replace mine_id = "BQT" if mine_name == "Bicquet"
replace mine_id = "GOR" if mine_name == "Gorée"
replace mine_id = "BQT-GOR" if mine_name == "Bicquet-Gorée" | mine_name == "Bicquet-Gorée réunis" | mine_name == "Biquet-Gorée" | mine_name == "Bicquet-Gorée réunies"
replace mine_subid_1 = "BQT" if mine_name == "Bicquet-Gorée" | mine_name == "Bicquet-Gorée réunis" | mine_name == "Biquet-Gorée" | mine_name == "Bicquet-Gorée réunies"
replace mine_subid_2 = "GOR" if mine_name == "Bicquet-Gorée" | mine_name == "Bicquet-Gorée réunis" | mine_name == "Biquet-Gorée" | mine_name == "Bicquet-Gorée réunies"
**
replace mine_id = "BNF" if mine_name == "Bienaufois"
**
replace mine_id = "BXW" if mine_name == "Bierleux-Werbomont"
**
replace mine_id = "BOR" if mine_name == "Bois d'Orjo"
**
replace mine_id = "BGS" if mine_name == "Bois de Gives et de Saint-Paul" | mine_name == "Bois de Gives & Saint Paul" | mine_name == "Bois de Gives"
**
replace mine_id = "BMX" if mine_name == "Bois de Marexhe" | mine_name == "Bois de Marexhe (Wohart)" | mine_name == "Wohart"
**
replace mine_id = "BSL" if mine_name == "Bois de Saint Lambert"
**
replace mine_id = "BMO" if mine_name == "Bois des Moines"
replace mine_id = "SAV" if mine_name == "Sart d'Avette"
replace mine_id = "SAV-BMO" if mine_name == "Sart d'Avette et Bois des Moines" | mine_name == "Sart-d'Avette & Bois des Moines"
replace mine_subid_1 = "SAV" if mine_name == "Sart d'Avette et Bois des Moines" | mine_name == "Sart-d'Avette & Bois des Moines"
replace mine_subid_2 = "BMO" if mine_name == "Sart d'Avette et Bois des Moines" | mine_name == "Sart-d'Avette & Bois des Moines"
**
replace mine_id = "BVL" if mine_name == "Bois du Val Saint Lambert" | mine_name == "Bois du Val Saint-Lambert"
**
replace mine_id = "BBR" if mine_name == "Bois-Borsu" | mine_name == "Bois et Borsu" | mine_name == "Bois Borsu"
**
replace mine_id = "BEA" if mine_name == "Bon Espoir aux Awirs" | mine_name == "Bon Espoir"
**
replace mine_id = "BEB" if mine_name == "Bon Espoir et Bons Amis"
**
replace mine_id = "BNR" if mine_name == "Bonier" | mine_name == "Bonnier"
**
replace mine_id = "ESH" if mine_name == "l'Espérance" & mine_community == "Herstal" | mine_name == "l'Espérance à Herstal" | mine_name == "Espérance" & mine_community == "Herstal" ///
	| mine_name == "Espérance et Violette" | mine_name == "Espérance à Herstal" | mine_name == "Bonne Espérance"

replace mine_id = "ESA" if mine_name == "Espérance à Moha" 

replace mine_id = "ESS" if mine_name == "Espérance" & mine_community == "Seraing" 

replace mine_id = "BFR" if mine_name == "Bonne Fortune" | mine_name == "Bonne-Fortune"
replace mine_id = "ESM" if mine_name == "Esperance à Montegnée" | mine_name == "l'Espérance à Montegnée" | mine_name == "Espérance à Montegnée" | mine_name == "l'Esperance à Montegnée" | mine_name == "Nouvelle Esperance à Montegnée" | mine_name == "Nouvelle Espérance"
replace mine_id = "BFR-ESM" if mine_name == "Bonne Fortune + l'Espérance à Montegnée" | mine_name == "Espérance et Bonne-Fortune" | mine_name == "Espérance à Montegnée-Bonne-Fortune" | mine_name == "l'Espérance à Montegnée + Bonne Fortune" | mine_name == "Espérance à Montegnée + Bonne-Fortune"
replace mine_subid_1 = "BFR" if mine_name == "Bonne Fortune + l'Espérance à Montegnée" | mine_name == "Espérance et Bonne-Fortune" | mine_name == "Espérance à Montegnée-Bonne-Fortune" | mine_name == "l'Espérance à Montegnée + Bonne Fortune" | mine_name == "Espérance à Montegnée + Bonne-Fortune"
replace mine_subid_2 = "ESM" if mine_name == "Bonne Fortune + l'Espérance à Montegnée" | mine_name == "Espérance et Bonne-Fortune" | mine_name == "Espérance à Montegnée-Bonne-Fortune" | mine_name == "l'Espérance à Montegnée + Bonne Fortune" | mine_name == "Espérance à Montegnée + Bonne-Fortune"
**
replace mine_id = "BSM" if mine_name == "Bossimé"
**
replace mine_id = "BOU" if mine_name == "Bouhouille"
**
replace mine_id = "BRT" if mine_name == "Burton" | mine_name == "Saint-Georges Burton"
**
replace mine_id = "CPO" if mine_name == "Champ d'Oiseau"
replace mine_id = "GMK" if mine_name == "Grands Makets"
replace mine_id = "GMK-CPO" if mine_name == "Grands Makets et Champ d'Oiseau" | mine_name == "Grands Makets et Champ d'Oiseau réunis"
replace mine_subid_1 = "GMK" if mine_name == "Grands Makets et Champ d'Oiseau" | mine_name == "Grands Makets et Champ d'Oiseau réunis"
replace mine_subid_2 = "CPO" if mine_name == "Grands Makets et Champ d'Oiseau" | mine_name == "Grands Makets et Champ d'Oiseau réunis"
**
replace mine_id = "CHT" if mine_name == "Chartreuse" | mine_name == "La Chartreuse"
replace mine_id = "VIO" if mine_name == "La Violette"
replace mine_id = "PYR" if mine_name == "Pyre"
replace mine_id = "VIO-PYR" if mine_name == "La Violette et Pyre" | mine_name == "La Violette" & year>=1848
replace mine_subid_1 = "VIO" if mine_name == "La Violette et Pyre" | mine_name == "La Violette" & year>=1848 
replace mine_subid_2 = "PYR" if mine_name == "La Violette et Pyre" | mine_name == "La Violette" & year>=1848 
replace mine_id = "CHT-VIO-PYR" if mine_name == "Chartreuse et Violette" | mine_name == "La Chartreuse et la Violette"  | mine_name == "La Chartreuse" & year>=1877 | mine_name == "Chartreuse" & year>=1877
replace mine_subid_1 = "CHT" if mine_name == "Chartreuse et Violette" | mine_name == "La Chartreuse et la Violette" | mine_name == "La Chartreuse" & year>=1877 | mine_name == "Chartreuse" & year>=1877
replace mine_subid_2 = "VIO" if mine_name == "Chartreuse et Violette" | mine_name == "La Chartreuse et la Violette" | mine_name == "La Chartreuse" & year>=1877 | mine_name == "Chartreuse" & year>=1877
replace mine_subid_3 = "PYR" if mine_name == "Chartreuse et Violette" | mine_name == "La Chartreuse et la Violette" | mine_name == "La Chartreuse" & year>=1877 | mine_name == "Chartreuse" & year>=1877
replace mine_id = "CHT" if mine_name == "Chartreuse"  & year>=1900 | mine_name == "La Chartreuse"  & year>=1900

**
replace mine_id = "CHS" if mine_name == "Chateau du Sart"
**
replace mine_id = "CDN" if mine_name == "Chaudin"
**
replace mine_id = "CRT" if mine_name == "Cheratte"
**
replace mine_id = "CRL" if mine_name == "Chertal"
**
replace mine_id = "CWN" if mine_name == "Chéneux Wahairon" | mine_name == "Chéneux-Wahairon" | mine_name == "Wahairon"
**
replace mine_id = "CLV" if mine_name == "Clavier"
**
replace mine_id = "COC" if mine_name == "Cockerill"
**
replace mine_id = "COL" if mine_name == "Colladios" | mine_name == "Coune et Colladios"
replace mine_id = "COQ" if mine_name == "Valentin Coq"
replace mine_id = "COQ-COL" if mine_name == "Valentin Coq et Colladios" | mine_name == "Valentin Coq et Colladios réunis"
replace mine_subid_1 = "COQ" if mine_name == "Valentin Coq et Colladios" | mine_name == "Valentin Coq et Colladios réunis"
replace mine_subid_2 = "COL" if mine_name == "Valentin Coq et Colladios" | mine_name == "Valentin Coq et Colladios réunis"
**
replace mine_id = "CNC" if mine_name == "Concorde"
**
replace mine_id = "CTN" if mine_name == "Couthuin"
**
replace mine_id = "CWT" if mine_name == "Cowette" | mine_name == "Cowette-Rufin"
**
replace mine_id = "CHY" if mine_name == "Crahay"
**
replace mine_id = "DSZ" if mine_name == "De Senzeilles"
**
replace mine_id = "ENG" if mine_name == "Engis" | mine_name == "Mine de houille Société d'Engis" | mine_name == "Société Métall. d'Engis (houille)"
**
replace mine_id = "ENV" if mine_name == "Envoz"
**
replace mine_id = "ESW" if mine_name == "Espérance à Wanze" | mine_name == "Espérance" & mine_community == "Wanze" | mine_name == "l'Espérance à Wanze"
**
replace mine_id = "FLS" if mine_name == "Falisolle"
**
replace mine_id = "VLM" if mine_name == "Faudeur" | mine_name == "Vinalmont (Faudeur)" | mine_name == "Vinalmont"
**
replace mine_id = "FLO" if mine_name == "Flône"
**
replace mine_id = "FPQ" if mine_name == "Fond Piquette" | mine_name == "Macy: Fond Piquette" | mine_name == "Fond de Piquette" 
replace mine_id = "MCY" if mine_name == "Macy" | mine_name == "Macy: Macy" 
replace mine_merger = 1 if mine_name == "Macy: Fond Piquette" | mine_name == "Macy: Macy"
replace mine_merger_id = "MCY-FPQ" if mine_name == "Macy: Fond Piquette" | mine_name == "Macy: Macy"
replace mine_id = "MCY-FPQ"  if mine_name == "Macy" & year==1849 | mine_name == "Macy" & year==1856 | mine_name == "Macy" & year==1856 |  mine_name == "Macy" & year>=1875				
replace mine_subid_1 = "MCY" if mine_name == "Macy" & year==1849 | mine_name == "Macy" & year==1856 | mine_name == "Macy" & year==1856 |  mine_name == "Macy" & year>=1875
replace mine_subid_2 = "FPQ" if mine_name == "Macy" & year==1849 | mine_name == "Macy" & year==1856 | mine_name == "Macy" & year==1856 |  mine_name == "Macy" & year>=1875
**
replace mine_id = "FFW" if mine_name == "Fond-des-Fawes" | mine_name == "Fond des Fawes"
replace mine_id = "FXL" if mine_name == "Foxhalle"
replace mine_id = "NOZ" if mine_name == "Nooz"
replace mine_id = "DON" if mine_name == "Donné"
replace mine_id = "ONH" if mine_name == "Onhons"
replace mine_id = "WER-ONH" if mine_name == "Werister et Onhons"
replace mine_subid_1 = "WER" if mine_name == "Werister et Onhons"
replace mine_subid_2 = "ONH" if mine_name == "Werister et Onhons"
replace mine_id = "WER-NOZ-DON" if mine_name == "Werister" | mine_name == "Werister Nooz" | mine_name == "Werister-Nooz" | ///
	mine_name == "Werister-Nooz-Donné" | mine_name == "Wérister, Nooz, Donné" | mine_name == "Werister etc"  | mine_name == "Wérister Nooz etc" | mine_name == "Werister-Nooz Donné"
replace mine_subid_1 = "WER" if mine_name == "Werister" | mine_name == "Werister Nooz" | mine_name == "Werister-Nooz" | ///
	mine_name == "Werister-Nooz-Donné" | mine_name == "Wérister, Nooz, Donné" | mine_name == "Werister etc"  | mine_name == "Wérister Nooz etc" | mine_name == "Werister-Nooz Donné"
replace mine_subid_2 = "ONH" if mine_name == "Werister" | mine_name == "Werister Nooz" | mine_name == "Werister-Nooz" | ///
	mine_name == "Werister-Nooz-Donné" | mine_name == "Wérister, Nooz, Donné" | mine_name == "Werister etc"  | mine_name == "Wérister Nooz etc" | mine_name == "Werister-Nooz Donné"
replace mine_subid_3 = "DON" if mine_name == "Werister" | mine_name == "Werister Nooz" | mine_name == "Werister-Nooz" | ///
	mine_name == "Werister-Nooz-Donné" | mine_name == "Wérister, Nooz, Donné" | mine_name == "Werister etc"  | mine_name == "Wérister Nooz etc" | mine_name == "Werister-Nooz Donné"
replace mine_id = "FXH" if mine_name == "Foxhalle et Hufnalle" | mine_name == "Petite Foxhalle et Hufnalle Réunies" | mine_name == "Société Foxhalle et Hufnalle Réunies"  | mine_name == "Foxhalle et Hufnalle réunies" | mine_name == "Petite Foxhalle et Hufnalle réunies"  | mine_name == "Petite Foxhalle et Hufnalle"
replace mine_id = "WER-NOZ-DON-FFW" if mine_name == "Werister Fond-des-Fawes" | mine_name == "Werister" & year >= 1876
replace mine_subid_1 = "WER" if mine_name == "Werister Fond-des-Fawes" | mine_name == "Werister" & year >= 1876
replace mine_subid_2 = "NOZ" if mine_name == "Werister Fond-des-Fawes" | mine_name == "Werister" & year >= 1876
replace mine_subid_3 = "DON" if mine_name == "Werister Fond-des-Fawes" | mine_name == "Werister" & year >= 1876
replace mine_subid_4 = "FFW" if mine_name == "Werister Fond-des-Fawes" | mine_name == "Werister" & year >= 1876
replace mine_id = "WER-NOZ-DON-FFW-FXL" if mine_name == "Werister-Fond des Fawes-Foxhalle" | mine_name == "Werister" & year >= 1883
replace mine_subid_1 = "WER" if mine_name == "Werister-Fond des Fawes-Foxhalle" | mine_name == "Werister" & year >= 1883
replace mine_subid_2 = "NOZ" if mine_name == "Werister-Fond des Fawes-Foxhalle" | mine_name == "Werister" & year >= 1883
replace mine_subid_3 = "DON" if mine_name == "Werister-Fond des Fawes-Foxhalle" | mine_name == "Werister" & year >= 1883
replace mine_subid_4 = "FFW" if mine_name == "Werister-Fond des Fawes-Foxhalle" | mine_name == "Werister" & year >= 1883
replace mine_subid_5 = "FXL" if mine_name == "Werister-Fond des Fawes-Foxhalle" | mine_name == "Werister" & year >= 1883
**
replace mine_id = "GSD" if mine_name == "Genck-Sutendael"
**
replace mine_id = "GDW" if mine_name == "Godbille et Werpin"
**
replace mine_id = "GLL" if mine_name == "Guillaume Lambert"
**
replace mine_id = "GSL" if mine_name == "Gosson" | mine_name == "Gosson-Lagasse"  | mine_name == "Gosson Lagasse"
**
replace mine_id = "GFN" if mine_name == "Grand-Fontaine" | mine_name == "Grand Fontaine"
**
replace mine_id = "GBC" if mine_name == "Grande Bacnure"
**
replace mine_id = "GRY" if mine_name == "Groynne"
**
replace mine_id = "GLY" if mine_name == "Gély" | mine_name == "Gély Abbesses" | mine_name == "Gély Abesses et Hayes Pizard"
**
replace mine_id = "HBS" if mine_name == "Halbosart"
replace mine_id = "KVL" if mine_name == "Kivelterie"
replace mine_id = "HBS-KVL" if mine_name == "Halbosart-Kivelterie"
replace mine_subid_1 = "HBS" if mine_name == "Halbosart-Kivelterie"
replace mine_subid_2 = "KVL" if mine_name == "Halbosart-Kivelterie"
**
replace mine_id = "HSD" if mine_name == "Hasard"									
replace mine_id = "MLN" if mine_name == "Melin"
replace mine_id = "HSD-MLN" if mine_name == "Hasard-Mélin" | mine_name == "Hasard Melin" | mine_name == "Hasard" & year >= 1864
replace mine_subid_1 = "HSD" if mine_name == "Hasard-Mélin" | mine_name == "Hasard Melin" | mine_name == "Hasard" & year >= 1864
replace mine_subid_2 = "MLN" if mine_name == "Hasard-Mélin" | mine_name == "Hasard Melin" | mine_name == "Hasard" & year >= 1864
replace mine_id = "FLN" if mine_name == "Prés de Fléron" | mine_name == "Près de Fléron"
replace mine_id = "HSD-MLN-FLN" if mine_name == "Hasard-Fléron"
replace mine_subid_1 = "HSD" if mine_name == "Hasard-Fléron" 
replace mine_subid_2 = "MLN" if mine_name == "Hasard-Fléron"
replace mine_subid_3 = "FLN" if mine_name == "Hasard-Fléron"
**
replace mine_id = "HSQ" if mine_name == "Hasquette"
**
replace mine_id = "HZD" if mine_name == "Hazard"
**
replace mine_id = "HPX" if mine_name == "Herman et Pixherotte"
**
replace mine_id = "HLC" if mine_name == "Helchteren"
**
replace mine_id = "HRV" if mine_name == "Herve"
replace mine_id = "WGF" if mine_name == "Wergifosse"
replace mine_id = "HRV-WGF" if mine_name == "Herve Wergifosse" | mine_name == "Herve-Wergifosse" | mine_name == "Herve" & year > 1864
replace mine_subid_1 = "HRV" if mine_name == "Herve Wergifosse" | mine_name == "Herve-Wergifosse" | mine_name == "Herve" & year > 1864
replace mine_subid_2 = "WGF" if mine_name == "Herve Wergifosse" | mine_name == "Herve-Wergifosse" | mine_name == "Herve" & year > 1864
**
replace mine_id = "HLR" if mine_name == "Heure-le-Romain"
**
replace mine_id = "HMV" if mine_name == "Homvent" | mine_name == "Homvent Maldaccord" | mine_name == "Homvent-Maldaccord"
replace mine_id = "TSR" if mine_name == "Trou-Souris"
replace mine_id = "HLX" if mine_name == "Houlleux"
replace mine_id = "TSR-HLX-HMV" if mine_name == "Trou-Souris-Houlleux-Homvent" | mine_name == "Trou Souris-Houlleux-Homvent"
replace mine_subid_1 = "TSR" if mine_name == "Trou-Souris-Houlleux-Homvent" | mine_name == "Trou Souris-Houlleux-Homvent"
replace mine_subid_2 = "HLX" if mine_name == "Trou-Souris-Houlleux-Homvent" | mine_name == "Trou Souris-Houlleux-Homvent"
replace mine_subid_3 = "HMV" if mine_name == "Trou-Souris-Houlleux-Homvent" | mine_name == "Trou Souris-Houlleux-Homvent"
**
replace mine_id = "HLZ" if mine_name == "Horloz"
**
replace mine_id = "HLT" if mine_name == "Houlteau"
**
replace mine_id = "HOU" if mine_name == "Housse"
**
replace mine_id = "HHL" if mine_name == "Houthaelen"
**
replace mine_id = "HTT" if mine_name == "Houtteau"
**
replace mine_id = "IVZ" if mine_name == "Ivoz"
replace mine_id = "RMT" if mine_name == "Ramet"
replace mine_id = "IVZ-RMT" if mine_name == "Ivoz Ramet"
replace mine_subid_1 = "IVZ" if mine_name == "Ivoz Ramet"
replace mine_subid_2 = "RMT" if mine_name == "Ivoz Ramet"
**
replace mine_id = "JBN" if mine_name == "Jambe"
replace mine_id = "BNU" if mine_name == "Bois-Noust"
replace mine_id = "JBN-BNU" if mine_name == "Jambe Bois Noust" | mine_name == "Jambe et Bois-Noust" | mine_name == "Jambe et Bois Noust"
replace mine_subid_1 = "JBN" if mine_name == "Jambe Bois Noust" | mine_name == "Jambe et Bois-Noust" | mine_name == "Jambe et Bois Noust"
replace mine_subid_2 = "BNU" if mine_name == "Jambe Bois Noust" | mine_name == "Jambe et Bois-Noust" | mine_name == "Jambe et Bois Noust"
replace mine_id = "LPL" if mine_name == "La Slante"
replace mine_id = "LPL-JBN-BNU" if mine_name == "La Slante-Jambe" | mine_name == "La Slante-Jambe Bois Noust" | mine_name == "La Slante-Jambe-Bois Noust" | mine_name == "La Slante, Jambe et Bois Noust"
replace mine_subid_1 = "LPL" if mine_name == "La Slante-Jambe" | mine_name == "La Slante-Jambe Bois Noust" | mine_name == "La Slante-Jambe-Bois Noust" | mine_name == "La Slante, Jambe et Bois Noust"
replace mine_subid_2 = "JBN" if mine_name == "La Slante-Jambe" | mine_name == "La Slante-Jambe Bois Noust" | mine_name == "La Slante-Jambe-Bois Noust" | mine_name == "La Slante, Jambe et Bois Noust"
replace mine_subid_3 = "BNU" if mine_name == "La Slante-Jambe" | mine_name == "La Slante-Jambe Bois Noust" | mine_name == "La Slante-Jambe-Bois Noust" | mine_name == "La Slante, Jambe et Bois Noust"
**
replace mine_id = "JNS" if mine_name == "Jeanson"
**
replace mine_id = "JHY" if mine_name == "Jehay"
**
replace mine_id = "JMP" if mine_name == "Jemeppe" | mine_name == "Jemeppes"
**
replace mine_id = "JML" if mine_name == "Jupille"
**
replace mine_id = "LHY" if mine_name == "La Haye"
**
replace mine_id = "LRC" if mine_name == "La Rochette"
**
replace mine_id = "CHA" if mine_name == "Le Château"
**
replace mine_id = "LHX" if mine_name == "Lhoneux"
**
replace mine_id = "LNT" if mine_name == "Lonette"
**
replace mine_id = "LOY" if mine_name == "Loyers"
**
replace mine_id = "LUR" if mine_name == "Lurtay"
replace mine_id = "OHY" if mine_name == "Oulhaye"
replace mine_id = "OHY-LUR" if mine_name == "Oulhaye-Lurtay"
replace mine_subid_1 = "OHY" if mine_name == "Oulhaye-Lurtay"
replace mine_subid_2 = "LUR" if mine_name == "Oulhaye-Lurtay"
**
replace mine_id = "MAL" if mine_name == "Malonne"
**
replace mine_id = "MSM" if mine_name == "Malsemaine"
**
replace mine_id = "MRH" if mine_name == "Marihaye" 						
**
replace mine_id = "MHX" if mine_name == "Micheroux"
**
replace mine_id = "MIN" if mine_name == "Minerie" | mine_name == "Minerie-Herve" | mine_name == "Minerie Herve"	
**
replace mine_id = "MOH" if mine_name == "Moha"
**
replace mine_id = "MGN" if mine_name == "Moignelée"
replace mine_id = "TAM" if mine_name == "Tamine" | mine_name == "Tamines"
replace mine_id = "TAM-MGN" if mine_name == "Tamine-Moignelée" | mine_name == "Tamine-Moignelée réunis" | mine_name == "Tamines-Moignelée"
replace mine_subid_1 = "TAM" if mine_name == "Tamine-Moignelée" | mine_name == "Tamine-Moignelée réunis" | mine_name == "Tamines-Moignelée"
replace mine_subid_2 = "MGN" if mine_name == "Tamine-Moignelée" | mine_name == "Tamine-Moignelée réunis" | mine_name == "Tamines-Moignelée"
**
replace mine_id = "MOR" if mine_name == "Moreau"							
**
replace mine_id = "MST" if mine_name == "Moustier" | mine_name == "Moustiers"
**
replace mine_id = "NVC" if mine_name == "Neufcour" | mine_name == "Neuve Cour" | mine_name == "Neuvecour"
**
replace mine_id = "NVM" if mine_name == "Nouvelle-Montagne" | mine_name == "Nouvelle Montagne" | mine_name == "Nouvelle Montagne à Engis"				
**
replace mine_id = "OUG" if mine_name == "Ougrée"
**
replace mine_id = "PXD" if mine_name == "Paix-Dieu"
**
replace mine_id = "PBJ" if mine_name == "Patience et Beaujonc" | mine_name == "Patience-Beaujonc"
**
replace mine_id = "PBC" if mine_name == "Petite Bacnure"
**
replace mine_id = "PFR" if mine_name == "Pouillou-Fourneau"
**
replace mine_id = "QJN" if mine_name == "Quatre Jean" | mine_name == "Quatrejean"
**
replace mine_id = "SHD" if mine_name == "S Hudelin" | mine_name == "Saint Hadelin" | mine_name == "Saint Hudelin"  | mine_name == "Saint-Hadelin"							
**
replace mine_id = "SLB" if mine_name == "Saint Lambert" | mine_name == "Saint-Lambert"
**
replace mine_id = "SBR" if mine_name == "Sainte Barbe"
**
replace mine_id = "SBL" if mine_name == "Sart Berleur" | mine_name == "Sart au Berleur" | mine_name == "Sarts-Berleur" | mine_name == "Sarts-au-Berleur" | mine_name == "Corbeau-au-Berleur"
**
replace mine_id = "SCL" if mine_name == "Sclessin" | mine_name == "Sclessin (Bois d'Avroy)" | mine_name == "Bois d'Avroy"
replace mine_id = "VBT" if mine_name == "Val Benoit"
replace mine_id = "SCL-VBT" if mine_name == "Sclessin-Val Benoit" | mine_name == "Sclessin-Val-Benoit" 
replace mine_subid_1 = "SCL" if mine_name == "Sclessin-Val Benoit" | mine_name == "Sclessin-Val-Benoit" 
replace mine_subid_2 = "VBT" if mine_name == "Sclessin-Val Benoit" | mine_name == "Sclessin-Val-Benoit" 
**
replace mine_id = "SLS" if mine_name == "Seilles"
**
replace mine_id = "SMM" if mine_name == "Site de Mornimont"
**
replace mine_id = "SBN" if mine_name == "Six Bonniers"
**
replace mine_id = "SOY" if mine_name == "Soye"
replace mine_id = "FLX" if mine_name == "Floriffoux"
replace mine_id = "FLF" if mine_name == "Floreffe"
replace mine_id = "FLW" if mine_name == "Flawinne"
replace mine_id = "LLA" if mine_name == "La Lache"
replace mine_id = "SOY-FLX-FLF-FLW-LLA" if mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache et extensions" | mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache"
replace mine_subid_1 = "SOY" if mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache et extensions" | mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache"
replace mine_subid_2 = "FLX" if mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache et extensions" | mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache"
replace mine_subid_3 = "FLF" if mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache et extensions" | mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache"
replace mine_subid_4 = "FLW" if mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache et extensions" | mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache"
replace mine_subid_5 = "LLA" if mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache et extensions" | mine_name == "Soye, Floriffoux, Floreffe, Flawinne, La Lache"
**
replace mine_id = "SPY" if mine_name == "Spy"
**
replace mine_id = "STT" if mine_name == "Statte"
**
replace mine_id = "STP" if mine_name == "Steppes" | mine_name == "Steppes Refroideur" | mine_name == "Steppes, Refroideur et Fourchette-Poncelet" | mine_name == "Steppes, Refroideur etc" | mine_name == "Steppes-Refroideur" ///
	| mine_name == "Steppes etc" | mine_name == "Steppes Refroideur etc" | mine_name == "Fourchette, Refroideur, Steppes" | mine_name == "Steppes-Refroideur etc." | mine_name == "Steppes, Refroideur etc."
**
replace mine_id = "SDR" if mine_name == "Strud et Rouvroy" |  mine_name == "Stud-Rouvroy"
**
replace mine_id = "TRV" if mine_name == "Taravisée"
**
replace mine_id = "TMX" if mine_name == "Temploux"
**
replace mine_id = "VND" if mine_name == "Val-Notre-Dame"
**
replace mine_id = "VLN" if mine_name == "Velaine" | mine_name == "Verlaine"	| mine_name == "Velaine et Jemeppe-Nord" | mine_name == "Velaine-Jemeppe Nord"			
**
replace mine_id = "VIM" if mine_name == "Vieille-Montagne"
**
replace mine_id = "VLB" if mine_name == "Villers-le-Bouillet"
**
replace mine_id = "WDR" if mine_name == "Wandre"
**
replace mine_id = "WNZ" if mine_name == "Wanze"
**
replace mine_id = "WSG" if mine_name == "Winterslag"
**
replace mine_id = "WHT" if mine_name == "Wohart"
**
replace mine_id = "XHL" if mine_name == "Xhilette"
**
replace mine_id = "ZLD" if mine_name == "Zolder"
**
